package com.example.meitu.api.common;

public class UserLoginContextHolder {
    private static final InheritableThreadLocal<UserContext> REQUEST_CONTEXT_INHERITABLE_THREAD_LOCAL = new InheritableThreadLocal();

    public UserLoginContextHolder() {
    }

    public static UserContext get() {
        return (UserContext)REQUEST_CONTEXT_INHERITABLE_THREAD_LOCAL.get();
    }

    public static void set(UserContext context) {
        REQUEST_CONTEXT_INHERITABLE_THREAD_LOCAL.set(context);
    }

    public static void remove() {
        REQUEST_CONTEXT_INHERITABLE_THREAD_LOCAL.remove();
    }
}
